package xyz.yuanjilu.test.aop;

import org.aopalliance.intercept.MethodInterceptor;
import org.aopalliance.intercept.MethodInvocation;

public class GreetingMethodInterceptor implements MethodInterceptor{

	@Override
	public Object invoke(MethodInvocation invocation) throws Throwable {
		Object[] arguments = invocation.getArguments();
		Object object = arguments[0];
		System.out.println("欢迎："+object);
		Object proceed = invocation.proceed();
		System.out.println("再见："+object);
		return proceed;
	}

}
